﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BTKERP.DAL.DataAccess;
using BTKERP.IDAL.Inventory;
using BTKERP.Model.Inventory;

namespace BTKERP.DAL.Inventory
{
    public class RequisitionDeliveryMasterDAL : DBContext
    {
        public IList<RequisitionDeliveryMasterInfo> GetRequisitionDeliveryMasters()
        {
            ExSQLCommand cmd = new ExSQLCommand("usp_SelectRequisitionDeliveryMastersAll");
            return GetEntityList<RequisitionDeliveryMasterInfo>(cmd);
        }

        public RequisitionDeliveryMasterInfo GetRequisitionDeliveryMasterById(int id)
        {
            ExSQLCommand cmd = new ExSQLCommand("usp_SelectRequisitionDeliveryMaster");
            cmd.AddParameter("@Id", id);
            return GetSingleEntity<RequisitionDeliveryMasterInfo>(cmd);
        }
    }
}
